On the paypal TUT for flask, I copy/pasted all the provided code. When I process a payment using paypal sandbox, I get redirected to success.html as expected, however, when i check my DB, it's saying the set is empty. Any input on why it might not be entering th DB?
You must be logged in to post. Please login or register an account.
Have you checked /tmp/ipnout.txt? That will likely have some more useful info for you.
-Harrison 8 years ago
You must be logged in to post. Please login or register an account.
I can't even find this .txt file on my computer. Something else must be wrong...let me stare at it for a while.
-cdowney102@gmail.com 8 years ago
You must be logged in to post. Please login or register an account.
If you're following the tutorial: https://pythonprogramming.net/paypal-flask-tutorial/
We're sending it to /tmp/ipnout.txt (which assumes Linux/Mac, you would use a different path on a windows machine/server)
-Harrison 8 years ago
You must be logged in to post. Please login or register an account.
I'm on a macbook pro. I threw some print statements in and it looks like i'm having an issue with notify_url..? it's not even rendering (or notifying) me on that URL....any debugging tips for that?
--[edit] the ipn function isn't even being called for me after a purchase is made.
-cdowney102@gmail.com 8 years ago
Last edited 8 years ago
You must be logged in to post. Please login or register an account.
Right, so the notify_url is part of the form that you're sending into paypal, which should have YOURWEBSITE/ipn/ as the path.
-Harrison 8 years ago
You must be logged in to post. Please login or register an account.
definitely. I've copy/pasted this url to ensure it's correct (http://127.0.0.1:5000/ipn/) and still nothing
You must be logged in to post. Please login or register an account.
I'm reading now that it should be impossible to process the ipn on local host. But now I am wondering why you were able to do it then...
-cdowney102@gmail.com 8 years ago
You must be logged in to post. Please login or register an account.
Right, you wouldn't be able to use 127.0.0.1 like you're trying to. The whole reason it works is you send data to PayPal, and then PayPal sends it back to you in a sort of "confirmation" of "this is what you sent us, is that right?" So, you need to do this on a web server.
I didn't do it on localhost, so that's why I didn't have this problem.
-Harrison 8 years ago
Last edited 8 years ago
You must be logged in to post. Please login or register an account.